{layout name="common/layout"/}

<style>
  .ny_ly .ljtj {
    background: #12257c;
    cursor: pointer;
  }
  .ny_ly .ljtj:hover {
    box-shadow: 0px 2px 10px #333;
  }
  .contant_cont .title::after {
    background: #12257c;
  }
  .contant_cont .section_1 {
    padding: 50px 0 125px;
  }
  .ny_lx .nr .d_t .bt {
    border-radius: 0 0 0 50px;
    background: #12257c;
    width: 500px;
    height: 90px;
    line-height: 90px;
    font-size: 28px;
  }
</style>
<div class="public_banner">
  <div class="img w100 h100">
    <img src="__ADDON__/xnr/image/banner_26.png" class="w100 h100" alt="" />
  </div>
  <div class="ban_cont w1300">
    <!--            <div class="title">联系我们</div>-->
    <!--            <div class="title_en">contact us</div>-->
  </div>
</div>
<div class="contant_cont">
  <div class="section_1 w1300">
    <div class="title">联系我们</div>
    <div class="subhead">CONTACT US</div>
    <div class="ny_lx">
      <div class="con">
        <div class="nr">
          <h3 class="wow fadeInUp" data-wow-delay="0.6s">
            浙江省舟山市定海区临城街道百川道11号A11-1502
          </h3>
          <div class="d_t wow fadeInUp" data-wow-delay="0.6s">
            <div class="bt">浙江欣挪瑞海洋科技有限公司</div>
            <img src="__ADDON__/xnr/image/dt.png" />
          </div>
          <ul class="wow fadeInUp" data-wow-delay="0.6s">
            <li>
              <p>
                <img
                  src="__ADDON__/xnr/image/icon_17.png"
                  class="middle"
                  alt=""
                />舟山
              </p>
              <p>
                <img
                  src="__ADDON__/xnr/image/icon_18.png"
                  class="middle"
                  alt=""
                />0580-2060703
              </p>
            </li>
            <li>
              <div>
                <p>
                  <img
                    src="__ADDON__/xnr/image/icon_17.png"
                    class="middle"
                    alt=""
                  />北京
                </p>
                <p>
                  <img
                    src="__ADDON__/xnr/image/icon_18.png"
                    class="middle"
                    alt=""
                  />010-82526998
                </p>
              </div>
            </li>
            <li>
              <div>
                <p>
                  <img
                    src="__ADDON__/xnr/image/icon_17.png"
                    class="middle"
                    alt=""
                  />无锡
                </p>
                <p>
                  <img
                    src="__ADDON__/xnr/image/icon_18.png"
                    class="middle"
                    alt=""
                  />0510-83595670
                </p>
              </div>
            </li>
          </ul>
        </div>
        <div class="clear"></div>
      </div>
      <div class="ny_ly">
        <div class="con">
          <div class="title">联系方式</div>
          <div class="subhead">contact method</div>
          <form
            method="post"
            class=""
            autocomplete="off"
            novalidate=""
            id="postform1"
            action="{:addon_url('cms/diyform/post',[':diyname' => 'message'])}"
          >
            <input type="hidden" name="__diyname__" value="message" />
            {:token()}
            <ul class="ny_ul">
              <li class="wow fadeInUp" data-wow-delay="0.6s">
                <p>您的姓名</p>
                <input type="text" name="row[nam]" id="nam" value="" />
              </li>
              <li class="wow fadeInUp" data-wow-delay="0.6s">
                <p>邮箱</p>
                <input type="text" name="row[em]" id="em" value="" />
              </li>
              <li class="wow fadeInUp" data-wow-delay="0.6s">
                <p>电话</p>
                <input type="text" name="row[pho]" id="pho" value="" />
              </li>
              <li class="wow fadeInUp" data-wow-delay="0.6s">
                <p>您所在公司</p>
                <input type="text" name="row[com]" id="com" value="" />
              </li>
              <li class="wow fadeInUp" data-wow-delay="0.6s">
                <p>您选择您感兴趣的产品或解决方案</p>
                <input
                  type="text"
                  name="row[gxq]"
                  id="gxq"
                  value="产品或解决方案1"
                  style="display: none"
                />
                <select name="点击选择" size="1">
                  <option>船舶一张屏</option>
                  <option>S100海图</option>
                  <option>WEB海图矢量引擎</option>
                  <option>智船云平台</option>
                  <option>电子海图与显示系统(ECDIS)</option>
                </select>
              </li>
              <div class="clear"></div>
            </ul>
          </form>
          <div class="ljtj wow fadeInUp btn1" data-wow-delay="0.6s">
            立即提交
          </div>
        </div>
      </div>
    </div>
  </div>
</div>

<script>
  var mySwiper = new Swiper(".swiper", {
    autoplay: true, //可选选项，自动滑动
    loop: true,
    spaceBetween: 50,
    slidesPerView: 3,
  });
</script>
<script>
  $(".chose").change(function () {
    var val = $(this).val();
    $("#content").val(val);
  });
  var isloading = false;
  $(".btn1").on("click", function () {
    if (isloading) {
      return;
    }
    var targetUrl = $("#postform1").attr("action");
    var data = $("#postform1").serialize();
    if (!check($("#postform1"))) {
      return;
    }
    isloading = true;
    $.ajax({
      type: "post",
      url: targetUrl,
      cache: false,
      data: data, //重点必须为一个变量如：data
      //dataType:'json',
      success: function (data) {
        isloading = false;
        if (data.code == 1) {
          window._agl && window._agl.push(["track", ["success", { t: 3 }]]);
          alert("提交成功，我们会尽快与您联系！");
        } else {
          alert("请勿重复操作");
          alert(data.msg);
        }
      },
      error: function () {
        isloading = false;
        alert("请求失败");
      },
    });
  });

  function check(theform2, sp) {
    var str =
      "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ,./'[]{}`1234567890-=\~!@#$%^&*()_+|?><:";
    var names = $(theform2).find("#names").val();
    var email = $(theform2).find("#email").val();
    var company = $(theform2).find("#company").val();
    var mobile = $(theform2).find("#mobile").val();
    var content = $(theform2).find("#content").val();
    if (names == "") {
      alert("请输入您的姓名");
      // theform2.other.focus();
      return false;
    }
    if (email == "") {
      alert("请输入您的邮箱");
      return false;
    }

    if (mobile == "") {
      alert("请输入您的手机号");
      return false;
    }

    if (company == "") {
      alert("请输入您所在公司");
      return false;
    }
    if (content == "") {
      alert("请选择您感兴趣的产品或解决方案");
      return false;
    }
    return true;
  }
</script>
